<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<c:set var="ctx" value="${pageContext.request.contextPath}"></c:set>
<!DOCTYPE html>
<html>

<head>

<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">

<title>H+ 后台主题UI框架 - 数据表格</title>
<meta name="keywords" content="H+后台主题,后台bootstrap框架,会员中心主题,后台HTML,响应式后台">
<meta name="description"
	content="H+是一个完全响应式，基于Bootstrap3最新版本开发的扁平化主题，她采用了主流的左右两栏式布局，使用了Html5+CSS3等现代技术">

<link rel="shortcut icon" href="${ctx}/favicon.ico">
<link href="${ctx}/css/bootstrap.min.css?v=3.3.6" rel="stylesheet">
<link href="${ctx}/css/font-awesome.css?v=4.4.0" rel="stylesheet">

<!-- Data Tables -->
<link href="${ctx}/css/plugins/dataTables/dataTables.bootstrap.css" rel="stylesheet">
<link href="${ctx}/css/animate.css" rel="stylesheet">
<link href="${ctx}/css/style.css?v=4.1.0" rel="stylesheet">
<!-- 全局js -->
<script src="${ctx}/js/jquery.min.js?v=2.1.4"></script>
<script src="${ctx}/js/bootstrap.min.js?v=3.3.6"></script>
<!-- 引入分页插件  -->
<script src="${ctx}/js/bootstrap-paginator.js"></script>

<script src="${ctx}/js/plugins/jeditable/jquery.jeditable.js"></script>

<!-- Data Tables -->
<script src="${ctx}/js/plugins/dataTables/jquery.dataTables.js"></script>
<script src="${ctx}/js/plugins/dataTables/dataTables.bootstrap.js"></script>

<!-- 引入日历插件js文件 -->
<script src="${ctx}/js/plugins/layer/laydate/laydate.js"></script>

<!-- 引入echarts js文件 -->
<script src="${ctx}/js/echarts.min.js"></script>

<!-- 引入弹框插件 layer  -->
<script src="${ctx}/js/plugins/layer/layer.min.js"></script>


<!-- 引入 Jquery.validate.js 表单验证框架 -->
<script src="${ctx}/js/jquery.validate.min.js"></script>
<script src="${ctx}/js/messages_zh.min.js"></script>

<!-- 自定义js -->
<script src="${ctx}/js/content.js?v=1.0.0"></script>
<script src="${ctx}/task/IssuedTask.js"></script>

<script src="${ctx}/js/echarts.min.js"></script>

<script type="text/javascript">
function getContextPath(){ 
	var pathName = document.location.pathname; 
	var index = pathName.substr(1).indexOf("/"); 
	var result = pathName.substr(0,index+1); 
	return result; 
}
	$(function(){
		var myChart = echarts.init(document.getElementById('main'));
        $.post(getContextPath()+'/IssuedTask.oa?cmd=echarts',function (data) {
        	myChart.setOption ({
            		title : {
            	        text: '任务紧急情况分布',
            	        x:'center'
            	    },
            	    tooltip : {
            	        trigger: 'item',
            	        formatter: "{a} <br/>{b} : {c} ({d}%)"
            	    },
            	    legend: {
            	        x : 'center',
            	        y : 'bottom',
            	        data:['一般','紧急','重大']
            	    },
            	    toolbox: {
            	        show : true,
            	        feature : {
            	            mark : {show: true},
            	            dataView : {show: true, readOnly: false},
            	            magicType : {
            	                show: true,
            	                type: ['pie', 'funnel']
            	            },
            	            restore : {show: true},
            	            saveAsImage : {show: true}
            	        }
            	    },
            	    calculable : true,
            	    series : [{
            	            name:'面积模式',
            	            type:'pie',
            	            radius : '55%',
            	            center : ['50%', '50%'],
            	            roseType : 'area',
            	            label: {
            	                normal: {
            	                    show: false
            	                },
            	                emphasis: {
            	                    show: true
            	                }
            	            },
            	            lableLine: {
            	                normal: {
            	                    show: false
            	                },
            	                emphasis: {
            	                    show: true
            	                }
            	            },
            	            data:[
            	                {value:data.normalCounts, name:'一般'},
            	                {value:data.rushCounts, name:'紧急'},
            	                {value:data.seriousCounts, name:'重大'}
            	            ]
            	    }]
            })
        },"json")
	})        
</script>

</head>

<body class="gray-bg">
	<div class="wrapper wrapper-content animated fadeInRight">
		<div class="row">
			<div class="col-sm-12">
				<div class="ibox float-e-margins">
				
					<div class="ibox-title">

						<div class="ibox-tools">
							<a class="collapse-link">
								<i class="fa fa-chevron-up"></i>
							</a>
							<a class="dropdown-toggle" data-toggle="dropdown" href="table_data_tables.html#">
								<i class="fa fa-wrench"></i>
							</a>
							<ul class="dropdown-menu dropdown-user">
								<li><a href="table_data_tables.html#">选项1</a></li>
								<li><a href="table_data_tables.html#">选项2</a></li>
							</ul>
							<a class="close-link">
								<i class="fa fa-times"></i>
							</a>
						</div>
					</div>
					
					<div class="ibox-content">							
						 <div id="main" style="width:500px;height:400px; margin-bottom:30px"></div>
						 
						 <div class="form-group" style="width:500px;height:40px; margin: 10px 0px">
							<div class="col-sm-offset-5 col-sm-8">
								<button class="btn btn-sm btn-primary" onclick="javascript:window.history.go(-1)">确认返回</button>
							</div>
						</div>
					</div>
				</div>
			</div>
		</div>
	</div>

</body>

</html>

